package com.shrct.businessprocess.purchase.impl;

import com.shrct.businessprocess.budget.RCBudgetDivision;
import com.shrct.businessprocess.budget.RCCostBreakDown;
import com.shrct.businessprocess.project.RCProjectMoney;
import com.shrct.businessprocess.purchase.RCCompanyQualityServiceBudget;
import com.shrct.businessprocess.purchase.impl.RCProductPurchaseBudgetImpl;
import com.shrct.businessprocess.purchase.proxy.RCCompanyQualityServiceBudgetProxy;
import edu.fudan.mylang.pf.IObjectFactory;
import java.util.ArrayList;
import java.util.Collection;
import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;
import org.eclipse.xtext.xbase.lib.CollectionLiterals;
import org.eclipse.xtext.xbase.lib.Procedures.Procedure1;

@Entity
@DiscriminatorValue("RCCOMPANYQUALITYSERVICEBUDGET_TYPE")
public class RCCompanyQualityServiceBudgetImpl extends RCProductPurchaseBudgetImpl implements RCCompanyQualityServiceBudget {
  public RCCompanyQualityServiceBudgetImpl() {
    super();
  }
  
  public RCCompanyQualityServiceBudgetImpl(final RCCostBreakDown cbd) {
    super( cbd);
    
  }
  
  public Collection<RCBudgetDivision> getBudgetDivisions() {
    ArrayList<RCBudgetDivision> _newArrayList = CollectionLiterals.<RCBudgetDivision>newArrayList();
    return _newArrayList;
  }
  
  public String getTypeId() {
    return "RCCompanyQualityServiceBudget";
  }
  
  public RCProjectMoney getContractPrice() {
    RCProjectMoney _productContractPrice = this.getProductContractPrice();
    return _productContractPrice;
  }
  
  public Double getContractTaxRate() {
    return this.getProductContractTaxRate();
  }
  
  public RCProjectMoney getNetPrice() {
    RCProjectMoney _productNetPrice = this.getProductNetPrice();
    return _productNetPrice;
  }
  
  public Double getNetTaxRate() {
    return this.getProductNetTaxRate();
  }
  
  public static RCCompanyQualityServiceBudget create(final RCCostBreakDown cbd, final IObjectFactory objectFactory) {
    com.shrct.businessprocess.purchase.RCCompanyQualityServiceBudget rCCompanyQualityServiceBudget = new com.shrct.businessprocess.purchase.impl.RCCompanyQualityServiceBudgetImpl(
    	cbd
    );
    objectFactory.create(rCCompanyQualityServiceBudget);
    return rCCompanyQualityServiceBudget;			
    
  }
  
  public static RCCompanyQualityServiceBudget createRCCompanyQualityServiceBudgetImpl(final RCCostBreakDown cbd, final IObjectFactory objectFactory, final Procedure1<RCCompanyQualityServiceBudget> init) {
    com.shrct.businessprocess.purchase.RCCompanyQualityServiceBudget rCCompanyQualityServiceBudget = new com.shrct.businessprocess.purchase.impl.RCCompanyQualityServiceBudgetImpl(
    	cbd
    );
    objectFactory.create(rCCompanyQualityServiceBudget);
    init.apply(rCCompanyQualityServiceBudget);
    
    return rCCompanyQualityServiceBudget;			
    
  }
  
  public RCCompanyQualityServiceBudgetProxy toProxy() {
    com.shrct.businessprocess.purchase.proxy.RCCompanyQualityServiceBudgetProxy proxy = new com.shrct.businessprocess.purchase.proxy.RCCompanyQualityServiceBudgetProxy();
    proxy.setId(this.getId());
    if(this instanceof edu.fudan.mylang.pf.INamedModelObject){
    	proxy.setName(((edu.fudan.mylang.pf.INamedModelObject)this).getEntityName());
    }
    return proxy;
    
  }
}
